vtd: fix interrupt remapping to handle SMI RTE's with uninitialized
authorKeir Fraser <keir.fraser@citrix.com>
Mon, 10 Nov 2008 10:41:41 +0000 (10:41 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Mon, 10 Nov 2008 10:41:41 +0000 (10:41 +0000)
commit82c9748428db42562eb954ae120e39194cd06b84
tree1fdcb0559e6e003ee6a906f6ceb3f62f29946739
parented675eda42fc5b2f522daa17ea446c7274e500ad
vtd: fix interrupt remapping to handle SMI RTE's with uninitialized
reserved fields

Some BIOS does not zero out reserve fields in IOAPIC RTE's.
clear_IO_APIC() zeroes out all RTE's except for RTE with MSI delivery
type.  This is a problem when the host OS converts SMI delivery type
to some other type but leaving the reserved field uninitialized.  This
can cause interrupt remapping table out of bound error if "format"
field is 1 and the uninitialized "index" field has a value that that
is larger than the maximum index of interrupt remapping table.

Signed-off-by: Allen Kay <allen.m.kay@intel.com>=
xen/drivers/passthrough/vtd/dmar.c
xen/drivers/passthrough/vtd/intremap.c